﻿<div class="row clearfix" [@routerTransition]>
    <div class="col-lg-12 col-md-12 col-sm-12 col-xs-12">
        <div class="card">
            <div class="header">
                <h2>
                    {{l('Users')}}
                </h2>
                <ul class="header-dropdown m-r--5">
                    <li class="dropdown">
                        <a href="javascript:void(0);" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false">
                            <i class="material-icons">more_vert</i>
                        </a>
                        <ul class="dropdown-menu pull-right">
                            <li><a href="javascript:void(0);" class=" waves-effect waves-block">Action</a></li>
                            <li><a href="javascript:void(0);" class=" waves-effect waves-block">Another action</a></li>
                            <li><a href="javascript:void(0);" class=" waves-effect waves-block">Something else here</a></li>
                        </ul>
                    </li>
                </ul>
            </div>
            <div class="body table-responsive">
                <table class="table">
                    <thead>
                        <tr>
                            <th>{{l('UserName')}}</th>
                            <th>{{l('FullName')}}</th>
                            <th>{{l('EmailAddress')}}</th>
                            <th>{{l('IsActive')}}</th>
                        </tr>
                    </thead>
                    <tbody>
                        <tr *ngFor="let user of users">
                            <td>{{user.userName}}</td>
                            <td>{{user.fullName}}</td>
                            <td>{{user.emailAddress}}</td>
                            <td>{{user.isActive ? l('Yes') : l('No')}}</td>
                        </tr>
                    </tbody>
                </table>
                <button type="button" data-toggle="modal" class="btn btn-primary btn-circle waves-effect waves-circle waves-float pull-right" (click)="createUser()">
                    <i class="material-icons">add</i>
                </button>
            </div>
        </div>
    </div>
</div>
<createUserModal #createUserModal (modalSave)="getUsers()"></createUserModal>